﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Collections;
using System.Runtime.Serialization;
using System.ServiceModel;

namespace AdminHome.WcfServiceGeneric.Models
{
    [DataContract]
    public class ShoppingCart : IShoppingCart
    {
        [DataMember]
        public List<String> products { get; set; }

        [DataMember]
        public String shoppingCartID { get; set; }

        [OperationContract]
        public void addProduct(String ProdID)
        {
            if (products == null) 
            {
                products = new List<String>();
            }
            products.Add(ProdID);
        }
        [OperationContract]
        public void deleteProduct(String ProdID)
        {
            if (products == null)
            {
                return;
            }
            products.Add(ProdID);
        }
    }
}